<?php


/**
 * Класс, отображающий расписание преподавателей
 *
 * @author asenko
 */
class teachers extends common implements content {
    
    const ERROR_DATA_NOT_FOUND_TEXT = 'Data not found',
            ERROR_DATA_NOT_FOUND_CODE = 2;
    
    public function selector() {
        $stmt = $this->getDB()->query('SELECT `PREPOD_ID` AS `ID`, `TITLE_FULL` AS `TITLE` FROM `SCHEDULE_PREPODS`');
        if (!$stmt) {
            throw new Exception(self::ERROR_DATA_NOT_FOUND_TEXT, self::ERROR_DATA_NOT_FOUND_CODE);
        }
        $result = $stmt->fetchAll(PDO::FETCH_ASSOC);
        return $result;
    }
    
    public function schedule($id) {
        ;
    }
}
